<?php
	// $Id: sessioncheck.php,v 1.3 2005/04/07 15:06:36 roflo1 Exp $
	/* load settings */
	if (!isset($_CONFIG))
		require 'config.php';

	if (!isset($_SESSION['adminID']))
		$_SESSION['adminID'] = -1;

	if ($_SESSION['adminID'] != -1)
	{
		if (time() - $_SESSION['lastInputTime'] >= $CFG_SESSIONTIMEOUT)
			$_SESSION['adminID'] = -1;
		else if (!isset($_GET['autoreload']))
			$_SESSION['lastInputTime'] = time();
	}

	if ($_SESSION['adminID'] == -1)
	{
			header('Location: index.php');
			exit();
	}
?>

